package com.heima.behavior.controller;


import com.heima.behavior.service.LikeService;
import com.heima.model.behavior.dtos.LikesBehaviorDto;
import com.heima.model.common.dtos.ResponseResult;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 文点赞行为控制器
 * @author huangjianfei
 * @date 2024/11/8
 */
@RestController
@RequestMapping("/api/v1/likes_behavior")
@RequiredArgsConstructor
public class LikeController {

    private final LikeService likeService;

    @PostMapping
    public ResponseResult likeApArticle(@RequestBody LikesBehaviorDto dto) {
        return likeService.likeApArticle(dto);
    }
}
